﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CommonSearchModule.SearchRes_Item;

namespace SearchIndexConsole.Lucene_ResItem
{
    internal class Program
    {
        private static void Main(string[] args)
        {
            CreateIndexFile c = new CreateIndexFile();
            c.Create();

            Console.WriteLine("完成。");

            string a = DateTime.Today.AddDays(-(int)DateTime.Today.DayOfWeek + 1).ToString();//本周一的日期
            string b = DateTime.Today.AddDays(7 - (int)DateTime.Today.DayOfWeek).ToString();//本周未的日期

            //本用第1天及最後1天
            string d = DateTime.Now.ToString("yyyy-MM-01");
            string f = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-01")).AddMonths(1).AddDays(-1).ToString();

            Console.WriteLine(a + b + d + f);
            Console.ReadKey();
        }
    }
}